<template>
    <div>
        <div class="frame">
            <div class="center">
                <div class="dot-1"></div>
                <div class="dot-2"></div>
                <div class="dot-3"></div>
                <div class="dot-4"></div>
                <div class="dot-5"></div>
                <div class="dot-6"></div>
                <div class="dot-7"></div>
                <div class="dot-8"></div>
            </div>
        </div>
        <btn-group :data="data"></btn-group>
    </div>
</template>

<script>
import btnGroup from "../../..//src/components/FooterButton/index.vue";

export default {
    name: "cssChallengeDay4",
    components: {btnGroup},
    data() {
        return {
            data: null
        };
    },
    created() {
        this.data = this.$route.params
    },
}
</script>

<style lang="scss" scoped>
$bezier: cubic-bezier(.21, .98, .6, .99);

.frame {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 400px;
  height: 400px;
  margin-top: -200px;
  margin-left: -200px;
  border-radius: 2px;
  box-shadow: 1px 2px 10px 0 rgba(0, 0, 0, 0.3);
  background: #000000;
  color: #fff;
}

.center {
  position: absolute;
  width: 220px;
  height: 220px;
  top: 90px;
  left: 90px;
}

.dot-1 {
  position: absolute;
  z-index: 8;
  width: 30px;
  height: 30px;
  top: 95px;
  left: 95px;
  background: #000000;
  border-radius: 50%;
  animation-fill-mode: both;
  animation: jump-jump-1 2s $bezier infinite alternate;
}

.dot-2 {
  position: absolute;
  z-index: 7;
  width: 60px;
  height: 60px;
  top: 80px;
  left: 80px;
  background: #fff;
  border-radius: 50%;
  animation-fill-mode: both;
  animation: jump-jump-2 2s $bezier infinite alternate;
  //infinite alternate 无线循环 反向
}

.dot-3 {
  position: absolute;
  z-index: 6;
  width: 90px;
  height: 90px;
  top: 65px;
  left: 65px;
  background: #000000;
  border-radius: 50%;
  animation-fill-mode: both;
  animation: jump-jump-3 2s $bezier infinite alternate;
}

.dot-4 {
  position: absolute;
  z-index: 5;
  width: 120px;
  height: 120px;
  top: 50px;
  left: 50px;
  background: #fff;
  border-radius: 50%;
  animation-fill-mode: both;
  animation: jump-jump-4 2s $bezier infinite alternate;
}

.dot-5 {
  position: absolute;
  z-index: 4;
  width: 150px;
  height: 150px;
  top: 35px;
  left: 35px;
  background: #000000;
  border-radius: 50%;
  animation-fill-mode: both;
  animation: jump-jump-5 2s $bezier infinite alternate;
}

.dot-6 {
  position: absolute;
  z-index: 3;
  width: 180px;
  height: 180px;
  top: 20px;
  left: 20px;
  background: #fff;
  border-radius: 50%;
  animation-fill-mode: both;
  animation: jump-jump-6 2s $bezier infinite alternate;
}

.dot-7 {
  position: absolute;
  z-index: 2;
  width: 210px;
  height: 210px;
  top: 5px;
  left: 5px;
  background: #000000;
  border-radius: 50%;
  animation-fill-mode: both;
  animation: jump-jump-7 2s $bezier infinite alternate;
}

.dot-8 {
  position: absolute;
  z-index: 1;
  width: 240px;
  height: 240px;
  top: -10px;
  left: -10px;
  background: #fff;
  border-radius: 50%;
  animation-fill-mode: both;
  animation: jump-jump-8 2s $bezier infinite alternate;
}

@keyframes jump-jump-1 {
  0%, 80% {
    box-shadow: 2px 2px 3px 2px rgba(0, 0, 0, 0.2);
    transform: scale(0);
  }

  100% {
    box-shadow: 10px 10px 15px 0 rgba(0, 0, 0, 0.3);
    transform: scale(1);
  }
}

@keyframes jump-jump-2 {
  0%, 70% {
    box-shadow: 2px 2px 3px 2px rgba(0, 0, 0, 0.2);
    transform: scale(0);
  }

  100% {
    box-shadow: 10px 10px 15px 0 rgba(0, 0, 0, 0.3);
    transform: scale(1);
  }
}

@keyframes jump-jump-3 {
  0%, 60% {
    box-shadow: 2px 2px 3px 2px rgba(0, 0, 0, 0.2);
    transform: scale(0);
  }

  100% {
    box-shadow: 10px 10px 15px 0 rgba(0, 0, 0, 0.3);
    transform: scale(1);
  }
}

@keyframes jump-jump-4 {
  0%, 50% {
    box-shadow: 2px 2px 3px 2px rgba(0, 0, 0, 0.2);
    transform: scale(0);
  }

  100% {
    box-shadow: 10px 10px 15px 0 rgba(0, 0, 0, 0.3);
    transform: scale(1);
  }
}

@keyframes jump-jump-5 {
  0%, 40% {
    box-shadow: 2px 2px 3px 2px rgba(0, 0, 0, 0.2);
    transform: scale(0);
  }

  100% {
    box-shadow: 10px 10px 15px 0 rgba(0, 0, 0, 0.3);
    transform: scale(1);
  }
}

@keyframes jump-jump-6 {
  0%, 30% {
    box-shadow: 2px 2px 3px 2px rgba(0, 0, 0, 0.2);
    transform: scale(0);
  }

  100% {
    box-shadow: 10px 10px 15px 0 rgba(0, 0, 0, 0.3);
    transform: scale(1);
  }
}

@keyframes jump-jump-7 {
  0%, 20% {
    box-shadow: 2px 2px 3px 2px rgba(0, 0, 0, 0.2);
    transform: scale(0);
  }

  100% {
    box-shadow: 10px 10px 15px 0 rgba(0, 0, 0, 0.3);
    transform: scale(1);
  }
}

@keyframes jump-jump-8 {
  0%, 10% {
    box-shadow: 2px 2px 3px 2px rgba(0, 0, 0, 0.2);
    transform: scale(0);
  }

  100% {
    box-shadow: 10px 10px 15px 0 rgba(0, 0, 0, 0.3);
    transform: scale(1);
  }
}
</style>